/*
 * uprint.h
 *
 * Serial port format print function.
 *
 * Copyright (C) 2022 Microwell, Inc.
 * Subject to the GNU Public License, version 2.
 *
 * Author: guoming<guoming@microwell.net>
 */
#ifndef __UPRINT_H__
#define __UPRINT_H__

#include "core.h"

#if (CONFIG_USING_DEBUG > 0)
uint16_t ex_10(uint8_t num);
void uprint_hex(uint8_t uart_port, uint16_t num);
void uprint_dec(uint8_t uart_port, uint16_t num);
void uprintf(uint8_t uart_port, const char *format, int16_t number);
#else
#define ex_10(num)                           (num)
#define uprint_hex(uart_port, num)           (uart_port, num)
#define uprint_dec(uart_port, num)           (uart_port, num)
#define uprintf(uart_port, format, num)      (uart_port, format, num)
#endif

#endif